package com.coffee.order.service.inquire.dao;

import com.coffee.order.api.inquire.query.InquireOrderTestingQuery;
import com.coffee.order.api.inquire.req.InquireOrderTestingReq;
import com.coffee.order.api.inquire.result.InquireOrderTestingResult;
import com.coffee.order.service.inquire.bean.InquireOrderTesting;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface InquireOrderTestingDao {
    public InquireOrderTesting findById(Integer id);

    public InquireOrderTesting findByInquireOrderId(Integer inquireOrderId);

    public InquireOrderTesting findByIdAndSupplierId(@Param("id") Integer id, @Param("supplierId") Integer supplierId);

    public InquireOrderTesting findByIdAndMerchantId(@Param("id") Integer id, @Param("merchantId") Integer merchantId);

    public InquireOrderTesting findByIdForUpdate(Integer id);

    public List<InquireOrderTesting> findByIds(@Param("idList") List<Integer> idList);

    public Integer count(@Param("param") InquireOrderTestingQuery param);

    public List<InquireOrderTesting> page(@Param("param") InquireOrderTestingQuery param, @Param("offset") Integer offset, @Param("rows") Integer rows);


    public List<InquireOrderTesting> list(@Param("param") InquireOrderTestingQuery param);

    public InquireOrderTesting findFirst(@Param("param") InquireOrderTestingQuery param);

    public Integer insert(InquireOrderTesting param);

    Integer insertBatch(List<InquireOrderTesting> list);

    public void updateById(@Param("param") InquireOrderTesting param);

    public Integer deleteById(Integer id);

    public Integer deleteByIds(List<Integer> idList);


    public Integer countByReq(@Param("param") InquireOrderTestingReq param);

    public List<InquireOrderTestingResult> pageByReq(@Param("param") InquireOrderTestingReq param, @Param("offset") Integer offset, @Param("rows") Integer rows);

}